.class public Lcom/kuguo/ui/d;
.super Landroid/graphics/drawable/Drawable;


# static fields
.field private static a:Landroid/graphics/drawable/Drawable;

.field private static b:Landroid/graphics/drawable/Drawable;

.field private static c:Landroid/graphics/drawable/Drawable;

.field private static d:I

.field private static e:I


# instance fields
.field private f:F


# direct methods
.method public constructor <init>(Landroid/content/Context;F)V
    .locals 1

    invoke-direct {p0}, Landroid/graphics/drawable/Drawable;-><init>()V

    iput p2, p0, Lcom/kuguo/ui/d;->f:F

    const-string v0, "kuguo_res/rating_empty.png"

    invoke-static {p1, v0}, Lcom/kuguo/c/d;->b(Landroid/content/Context;Ljava/lang/String;)Landroid/graphics/drawable/Drawable;

    move-result-object v0

    sput-object v0, Lcom/kuguo/ui/d;->a:Landroid/graphics/drawable/Drawable;

    const-string v0, "kuguo_res/rating_half.png"

    invoke-static {p1, v0}, Lcom/kuguo/c/d;->b(Landroid/content/Context;Ljava/lang/String;)Landroid/graphics/drawable/Drawable;

    move-result-object v0

    sput-object v0, Lcom/kuguo/ui/d;->b:Landroid/graphics/drawable/Drawable;

    const-string v0, "kuguo_res/rating_full.png"

    invoke-static {p1, v0}, Lcom/kuguo/c/d;->b(Landroid/content/Context;Ljava/lang/String;)Landroid/graphics/drawable/Drawable;

    move-result-object v0

    sput-object v0, Lcom/kuguo/ui/d;->c:Landroid/graphics/drawable/Drawable;

    sget-object v0, Lcom/kuguo/ui/d;->c:Landroid/graphics/drawable/Drawable;

    invoke-virtual {v0}, Landroid/graphics/drawable/Drawable;->getIntrinsicWidth()I

    move-result v0

    sput v0, Lcom/kuguo/ui/d;->d:I

    sget-object v0, Lcom/kuguo/ui/d;->c:Landroid/graphics/drawable/Drawable;

    invoke-virtual {v0}, Landroid/graphics/drawable/Drawable;->getIntrinsicHeight()I

    move-result v0

    sput v0, Lcom/kuguo/ui/d;->e:I

    return-void
.end method


# virtual methods
.method public draw(Landroid/graphics/Canvas;)V
    .locals 10

    const/4 v8, 0x0

    iget v0, p0, Lcom/kuguo/ui/d;->f:F

    float-to-double v0, v0

    invoke-static {v0, v1}, Ljava/lang/Math;->floor(D)D

    move-result-wide v0

    double-to-int v0, v0

    invoke-virtual {p0}, Lcom/kuguo/ui/d;->getBounds()Landroid/graphics/Rect;

    move-result-object v1

    iget v2, v1, Landroid/graphics/Rect;->left:I

    move v3, v2

    move v2, v8

    :goto_0
    if-ge v2, v0, :cond_0

    sget-object v4, Lcom/kuguo/ui/d;->c:Landroid/graphics/drawable/Drawable;

    iget v5, v1, Landroid/graphics/Rect;->top:I

    sget v6, Lcom/kuguo/ui/d;->d:I

    add-int/2addr v6, v3

    iget v7, v1, Landroid/graphics/Rect;->bottom:I

    invoke-virtual {v4, v3, v5, v6, v7}, Landroid/graphics/drawable/Drawable;->setBounds(IIII)V

    sget-object v4, Lcom/kuguo/ui/d;->c:Landroid/graphics/drawable/Drawable;

    invoke-virtual {v4, p1}, Landroid/graphics/drawable/Drawable;->draw(Landroid/graphics/Canvas;)V

    sget v4, Lcom/kuguo/ui/d;->d:I

    add-int/2addr v3, v4

    add-int/lit8 v2, v2, 0x1

    goto :goto_0

    :cond_0
    iget v2, p0, Lcom/kuguo/ui/d;->f:F

    int-to-float v4, v0

    cmpl-float v2, v2, v4

    if-lez v2, :cond_2

    sget-object v2, Lcom/kuguo/ui/d;->b:Landroid/graphics/drawable/Drawable;

    iget v4, v1, Landroid/graphics/Rect;->top:I

    sget v5, Lcom/kuguo/ui/d;->d:I

    add-int/2addr v5, v3

    iget v6, v1, Landroid/graphics/Rect;->bottom:I

    invoke-virtual {v2, v3, v4, v5, v6}, Landroid/graphics/drawable/Drawable;->setBounds(IIII)V

    sget-object v2, Lcom/kuguo/ui/d;->b:Landroid/graphics/drawable/Drawable;

    invoke-virtual {v2, p1}, Landroid/graphics/drawable/Drawable;->draw(Landroid/graphics/Canvas;)V

    sget v2, Lcom/kuguo/ui/d;->d:I

    add-int/2addr v2, v3

    add-int/lit8 v0, v0, 0x1

    move v9, v2

    move v2, v0

    move v0, v9

    :goto_1
    const/4 v3, 0x5

    sub-int v2, v3, v2

    move v3, v0

    move v0, v8

    :goto_2
    if-ge v0, v2, :cond_1

    sget-object v4, Lcom/kuguo/ui/d;->a:Landroid/graphics/drawable/Drawable;

    iget v5, v1, Landroid/graphics/Rect;->top:I

    sget v6, Lcom/kuguo/ui/d;->d:I

    add-int/2addr v6, v3

    iget v7, v1, Landroid/graphics/Rect;->top:I

    sget-object v8, Lcom/kuguo/ui/d;->a:Landroid/graphics/drawable/Drawable;

    invoke-virtual {v8}, Landroid/graphics/drawable/Drawable;->getIntrinsicHeight()I

    move-result v8

    add-int/2addr v7, v8

    invoke-virtual {v4, v3, v5, v6, v7}, Landroid/graphics/drawable/Drawable;->setBounds(IIII)V

    sget-object v4, Lcom/kuguo/ui/d;->a:Landroid/graphics/drawable/Drawable;

    invoke-virtual {v4, p1}, Landroid/graphics/drawable/Drawable;->draw(Landroid/graphics/Canvas;)V

    sget v4, Lcom/kuguo/ui/d;->d:I

    add-int/2addr v3, v4

    add-int/lit8 v0, v0, 0x1

    goto :goto_2

    :cond_1
    return-void

    :cond_2
    move v2, v0

    move v0, v3

    goto :goto_1
.end method

.method public getIntrinsicHeight()I
    .locals 1

    sget v0, Lcom/kuguo/ui/d;->e:I

    return v0
.end method

.method public getIntrinsicWidth()I
    .locals 1

    sget v0, Lcom/kuguo/ui/d;->d:I

    mul-int/lit8 v0, v0, 0x5

    return v0
.end method

.method public getOpacity()I
    .locals 1

    const/4 v0, 0x0

    return v0
.end method

.method public setAlpha(I)V
    .locals 0

    return-void
.end method

.method public setColorFilter(Landroid/graphics/ColorFilter;)V
    .locals 0

    return-void
.end method
